package plate

import (
	"container/list"
	"sync"
	"time"

	"gitee.com/wulalade/hwpack/lpr/aiApiT"
)

const (
	maxCache = 10
	maxLogic = 8
)

type CarResult_t struct {
	Car        aiApiT.Car //判断值
	AppearTime time.Time  //添加时间
	IsEmpty    bool       //是否为空
}

//每个区域
type Logic_t struct {
	Used          bool        //启用表示
	Now_CarResult CarResult_t //当前值
	Queue         *list.List  //缓存队列
}

//每个节点
type Node_t struct {
	//LostCount uint              //掉线次数统计
	//Status    uint              //当前状态
	Logic [maxLogic]Logic_t //当前结果
}

//总句柄
type PlateHandler struct {
	Nodes       sync.Map //储存所有节点的信息
	defProvince string   //默认地区 闽
	defCity     string   //默认城市 D
}

var (
	handler PlateHandler
)
